package com.rabbit.eap.framework.config.convert;

import com.rabbit.eap.framework.config.util.StringToDateUtil;
import org.springframework.core.convert.converter.Converter;

import java.util.Date;

/**
 * @projectName eap
 * @packageName com.rabbit.eap.framework.config.convert
 * @className StringToDateConverter
 * @author： rabbit
 * @version： 1.0
 * @since： 2020/4/27 20:46
 * <p>Description: StringToDateConverter
 * 日期转换器,将请求参数的日期字符串转换成java.util.Date类型
 * </p>

 */
public class StringToDateConverter implements Converter<String, Date> {

    @Override
    public Date convert(String source) {
        return StringToDateUtil.convert(source);
    }
}
